﻿<div class="path_menu">
    <div class="path_menu_item">
        <a href="@Url.Content("~/")">Home Page</a>
    </div>
    <div class="path_menu_item">
        <a href="@Url.Content("~/administrator/menus")">Menu</a>
    </div>
    <div class="path_menu_item">
        <a href="">Add new menu</a>
    </div>
</div>
<div class="path_menu context_menu">
    <a href="#">Danh sách sản phẩm</a> <span>|</span> <a href="#">Danh mục sản phẩm</a>
    <span>|</span> <a href="#">Đánh giá, nhận xét sản phẩm</a>
</div>
<form action="" method="post" enctype="multipart/form-data">
<div class="path_menu title_and_action">
    <div class="content_title">
        Add new menu
    </div>
    <div class="content_action">
        <div class="item_content_action">
            <div class="img_item_content_action" id="help_action">
            </div>
            <div class="text_item_content_action">
                Help
            </div>
        </div>
        <div class="item_content_action">
            <a href="@Url.Content("~/administrator/menus/")">
                <div class="img_item_content_action" id="go_back_action1">
                </div>
                <div class="text_item_content_action">
                    Close
                </div>
            </a>
        </div>
        <div class="item_content_action">
            <div class="img_item_content_action">
                <input type="submit" name="submit_menu" class="bt_category_submit" value="" />
            </div>
            <div class="text_item_content_action">
                Save
            </div>
        </div>
    </div>
    <!--#END content_action-->
</div>
<!--#END path_menu title_and_action-->
@if (ViewBag.error != null)
{
    <div class="path_menu error">
        @Html.Raw(ViewBag.error)
    </div>
}
@if (ViewBag.success != null)
{
    <div class="path_menu success">
        @Html.Raw(ViewBag.success)
    </div>
}
<!--===================================CHO DANH CHO VIEC SHOW FORM=================================================-->
<div class="path_menu">
    <div class="form_panel">
        <div class="tab_form_panel">
            <div class="item_tab_form_panel item_tab_form_panel_show" id="item_tab_form_panel1">
                Menu Detail
            </div>
        </div>
        <div class="content_form_panel">
            <div class="item_content_form_panel" id="item_content_form_panel1">
                <div class="item_item_content_form">
                    <div class="title_item_item_form">
                        <span>*</span> Menu Name
                    </div>
                    <div class="input_item_item_form">
                        <input type="text" class="txt_input_item_item" name="Name" id="Name-Item" value="@try
                                                                                          {@ViewBag.dataForm["Name"]}
                                                                                          catch { }"/>
                        <input type="hidden" class="txt_input_item_item" name="Alias" id="Alias-Item" value="@try
                                                                                                           {@ViewBag.dataForm["Alias"]}
                                                                                                           catch { }"/>
                    </div>
                </div>
                <div class="item_item_content_form">
                    <div class="title_item_item_form">
                        <span>*</span> Menu Controller
                    </div>
                    <div class="input_item_item_form">
                        <input type="text" class="txt_input_item_item" name="Controller" value="@try
                                                                                                {@ViewBag.dataForm["Controller"]}
                                                                                                catch { }"/>
                    </div>
                </div>
                <div class="item_item_content_form">
                    <div class="title_item_item_form">
                        <span>*</span> Menu Action
                    </div>
                    <div class="input_item_item_form">
                        <input type="text" class="txt_input_item_item" name="Action" value="@try
                                                                                            {@ViewBag.dataForm["Action"]}
                                                                                            catch { }"/>
                    </div>
                </div>
                <div class="item_item_content_form">
                    <div class="title_item_item_form">
                        <span>*</span> Icon(W:H ~ 1:1)
                    </div>
                    <div class="input_item_item_form">
                        <input type="file" class="" name="Icon" />
                    </div>
                </div>
                <div class="item_item_content_form">
                    <div class="title_item_item_form">
                        <span>*</span> Display
                    </div>
                    <div class="input_item_item_form">
                        @try
                        {
                            if (ViewBag.dataForm["Display"] != null && ViewBag.dataForm["Display"] == "on")
                            {
                            <input type="checkbox" name="Display" checked="checked" />
                            }
                            else
                            {
                            <input type="checkbox" name="Display" />
                            }
                        }
                        catch
                        {
                            <input type="checkbox" name="Display" />
                        }
                    </div>
                </div>
                <div class="item_item_content_form">
                    <div class="title_item_item_form">
                        <span>*</span> Parent menu
                    </div>
                    <div class="input_item_item_form">
                        <select size="10" name="Parent">
                            <option value="-2">Chose parent menu for this menu...</option>
                            <option value="-1" selected="selected">Sub menu</option>
                            @foreach (eProjectsSemIII.Models.Menus menu in ViewBag.parentMenu)
                            {
                                try
                                {
                                    if (menu.ID == Convert.ToInt16(ViewBag.dataForm["Parent"]))
                                    {
                                <option value="@menu.ID" selected="selected">@menu.Name</option>
                                    }
                                    else
                                    {
                                <option value="@menu.ID">@menu.Name</option>
                                    }
                                }
                                catch
                                {
                                <option value="@menu.ID">@menu.Name</option>
                                }
                            }
                        </select>
                    </div>
                </div>
                <div class="item_item_content_form">
                    <div class="title_item_item_form">
                        Description
                    </div>
                    <div class="input_item_item_form">
                        <textarea cols="" rows="" name="Description" class="txt_textarea_product">@try
                         {@ViewBag.dataForm["Description"]}
                         catch { }</textarea>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<!--================================#END CHO DANH CHO VIEC SHOW FORM===============================================-->
<div class="path_menu title_and_action">
    <div class="content_title">
        Add new menu
    </div>
    <div class="content_action">
        <div class="item_content_action">
            <div class="img_item_content_action" id="help_action1">
            </div>
            <div class="text_item_content_action">
                Help
            </div>
        </div>
        <div class="item_content_action">
            <a href="@Url.Content("~/administrator/menus/")">
                <div class="img_item_content_action" id="go_back_action">
                </div>
                <div class="text_item_content_action">
                    Close
                </div>
            </a>
        </div>
        <div class="item_content_action">
            <div class="img_item_content_action">
                <input type="submit" name="submit_menu" class="bt_category_submit" value="" />
            </div>
            <div class="text_item_content_action">
                Save
            </div>
        </div>
    </div>
    <!--#END content_action-->
</div>
<!--#END path_menu title_and_action-->
</form>
